#include "udpserver.hpp"
#include <memory>
#include <functional>

int main(int args, char* argv[])
{
    if(args != 2)
    {
        std::cout << "parameter num error!!!" << std::endl;
        exit(SERVER_PARAMETER_ERROR);
    }
    
    int _serverport = std::stoi(argv[1]);

    

    std::unique_ptr<udpserver> usvr = std::make_unique<udpserver>(_serverport); // C++14
    usvr->Initserver();
    usvr->start();

    return 0;
}